<%--
 *  File:    UserAuthorityInfo.jsp
 *  @Author: Kent Zhong
 *  Date:    2002/05/31
 *
 *  Copyright (C) 2000 - 2002 Oval Technologies, Inc.
 *  All rights reserved. 
 *
 *  This software is the confidential and proprietary information of Oval 
 *  Technologies, Inc. ("Confidential Information").  You shall not
 *  disclose such Confidential Information and shall use it only in
 *  accordance with the terms of the license agreement you entered into
 *  with Oval.
--%>


<%@ include file="/inc/SessionTimeout.inc"%>
<%@ page language="java" %>     
<%@ page import="java.util.*" %>
<%@ page import="org.apache.log4j.Category" %>
<%@ page import="com.oval.util.OvalLabel" %>

<%@ page contentType = "text/html;charset=UTF-8" %>
<%@ taglib uri="/WEB-INF/PageFlow.tld" prefix="PageFlow" %>
<%@ taglib uri="/WEB-INF/struts-logic.tld" prefix="logic" %>
<%@ taglib uri="/WEB-INF/oval-tag.tld" prefix="oval" %>
<%@ taglib uri="/WEB-INF/custom-tag.tld" prefix="custom" %>

<%
  //init param
  Category cat = Category.getInstance("jsp.UserAuthorityInfo"); 
   
  String strModuleName = "UPM";
  String privilegeCode = "Z0102,L401";
  
  HashMap userinfo = (HashMap)session.getAttribute("userinfo");
  
  cat.debug("The userinfo is :"+userinfo);
  cat.info("enter my page");
  
  
%>
<%@ include file="/inc/Security.inc" %>
<%@ include file="/inc/PageDefault.inc" %>

<html>
<head>
<title>UserAuthorityInfo</title>
<PageFlow:CheckPageFlow pageName="userauthorityinfo"/>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<link rel="stylesheet" href="../../css/<%= strLanguageCode %>/main.css" type="text/css">
<script language="JavaScript" src="../../css/<%= strLanguageCode %>/script.js"></script>
<script language="JavaScript" src="../../js/FuncLib.js"></script>
<%@ include file="/inc/SummaryDivision.inc" %>
<script language="JavaScript">

    function page_summary(actionvalue,orderbyname)
    {
      var editform = summaryPrepare(userauthorityinfoform,actionvalue,orderbyname);
      editform.action = "UserAuthorityInfo.jsp?<%= OvalTools.randomURL() %>";
      editform.target = "_self";
      isRunning = true;
      editform.submit();  
    }
<%--[SCRIPT]    [SCRIPT]--%>
</script>
</head>
<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
<form name="userauthorityinfoform" method="post" action="../../Dispatcher"  target="_parent">
    <input type="hidden" name="pagename" value="salesinvoiceinfo">
    <input type="hidden" name="actionname">   
    <input type="hidden" name="languagecode" value="<%=JspHelper.filterNull( session.getAttribute("languagecode") )%>">   
 <%
    Integer IntUserId=(Integer)pageContext.getAttribute("userid");
    if(IntUserId==null)
        IntUserId=new Integer(-1);
    
 %>
 <input  type=hidden name=userid value="<%=JspHelper.filterNull(IntUserId.intValue())%>">
<table width="100%" cellspacing="0" cellpadding="0" border="0">
  <%--form name="form1" method="post" action="UserGroupSummary.htm"--%>
    <tr> 
      <td valign="top"> 
        <table width="100%" border="0" cellspacing="0">
          <tr> 
            <td class="summary_top" ></td>
          </tr>
          <tr> 
            <td valign="middle" align="left" height="10"><img src="../../images/<%= strLanguageCode %>/quote.gif" width="16" height="11"> 
              <%=label.getLabelName("L_AuthorizationInfo")+label.getLabelName("L_Colon")%></td>    
          </tr>
        </table>
        <table border="1" cellspacing="0" bordercolorlight="#999999" bordercolordark="#FFFFFF" align="center" width="100%" cellpadding="0">
          <tr class="deepblue-left" > 
            <td class="title_center" width="90" ><%=label.getLabelName("L_PrivilegeCode")%></td>
            <td class="title_center" width="90" ><%=label.getLabelName("L_PrivilegeName")%></td>
            <td class="title_center" ><%=label.getLabelName("L_Description")%></td>
          </tr>
          <%
            Vector userauthoritysummary=(Vector)pageContext.getAttribute("userauthoritysummary");
            if(userauthoritysummary==null)
                userauthoritysummary=new Vector();
            cat.debug("userauthoritysummary is:"+userauthoritysummary);
            String strClassType="none";
            int i=0;
          %>
          <logic:iterate id="userauthoritysummaryitem" collection="<%= userauthoritysummary %>">
          <%
            if(i%2 == 1)
            {
              	strClassType = "td-listrom";
            }else{                    
              	strClassType = "none";
            }
            i++;
            cat.debug("loop "+i+"  :"+((HashMap)userauthoritysummaryitem).toString());
          %>
          <tr class="<%=JspHelper.filterNull(strClassType)%>"> 
            <td >&nbsp;<oval:write name="userauthoritysummaryitem" property="privilegecode"/></td>
            <td >&nbsp;<oval:write name="userauthoritysummaryitem" property="privilegename"/></td>
            <td >&nbsp;<oval:write name="userauthoritysummaryitem" property="privilegedesc"/></td>
          </tr>
          </logic:iterate>
          
          
          <tr> 
            <td colspan="3"> 
              <table width="100%" cellspacing="0" border="0">
                <%@ include file="/inc/SummaryAction.inc" %>
              </table>
            </td>
          </tr>
        </table>
        <table width="100%" border="0" cellspacing="0" cellpadding="0">
          <tr> 
            <td class="summary_top" ></td>
          </tr>
          <tr> 
            <td class="td_center"> 
                <a onclick="self.location.href='../../common/Blank.jsp?<%= OvalTools.randomURL() %>';"><custom:button type="1" label="L_Back" imgsrc="back.gif" border="0" style="width:60"/></a>
            </td>
          </tr>
        </table>
      </td>
    </tr>
  
</table>
</form>
</body>
</html>


